using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.Runtime.Serialization;
using ConvertEx = Openfree.Framework.Common.Convert;

public partial class HotImage_HotImage : System.Web.UI.UserControl
{
    protected void Page_Load(object sender, EventArgs e)
    {

    }

    public HotImageItem[] HotImageArray
    {
        get
        {
            if (ViewState[this.ClientID]==null)
            {
                HotImageItem[] hotImage = new HotImageItem[3];
                hotImage[0] = new HotImageItem();
                hotImage[1] = new HotImageItem();
                hotImage[2] = new HotImageItem();
                ViewState[this.ClientID] = hotImage;
                return hotImage;
            }
            else
            {

                return (HotImageItem[])ViewState[this.ClientID];
            }
        }

        set
        {
            ViewState[this.ClientID] = value;
        }
    }

    protected string GetImageUrl(int index)
    {
        return HotImageArray[index].ImageUrl;
    }

    protected string GetNavigateUrl(int index)
    {
        return HotImageArray[index].NavigateUrl;
    }

    protected string GetDescription(int index)
    {
        return HotImageArray[index].Description;
    }

    
}

[Serializable]
public class HotImageItem
{
    public string ImageUrl = string.Empty;
    public string NavigateUrl = string.Empty;
    public string Description = string.Empty;
}

